<%@ page contentType="text/html;charset=UTF-8"%>
<%@ taglib prefix="s" uri="/struts-tags"%>
<%@ include file="../common/taglibs.jsp"%>
<%@ page import="java.util.*"%>
<%@ page import="com.opensymphony.xwork2.ActionSupport"%>
<%@ page import="net.aiform.account.pojo.*"%>
<%@ page import="net.aiform.bean.Constant"%>
<%@ page import="net.aiform.template.pojo.*"%>
<%@ page import="ext.cjt.*"%>
<html>
	<head>
		<title>
		<%
			ActionSupport as_index = new ActionSupport();
			out.print( as_index.getText("sys.title", new String[] { as_index.getText("sys.name") }));
		%>
		</title>
	</head>
	<body>
		<%@ include file="../common/userInfo.jsp"%>
		<hr>
<div>
<%
	Template t = (Template) session.getAttribute(Constant.FORMTEMPLATE);
%>
<form action="${ctx}/t/dsn/save">
<table>
<tr>
	<td>次序</td>
	<td>名称</td>
	<td>编码</td>
	<td>类型</td>
	<td>长度</td>
	<td>默认值</td>
	<td>样例值/备选项</td>
	<td>约束条件</td>
	<td>说明</td>
	<td>是否隐藏</td>
</tr>
<tr>
	<td><input name="order_1" value="1" style="width:40px"/></td>
	<td><input name="name_1" value="姓名"/></td>
	<td><input name="code_1" value="NM" style="width:40px"/></td>
	<td>
		<select name="type_1" >
			<option value="1">字符串</option>
			<option value="2">整数</option>
			<option value="3">小数</option>
			<option value="4">日期</option>
			<option value="5">时间</option>
			<option value="6">日期时间</option>
			<option value="7">单选</option>
			<option value="8">多选</option>
			<option value="9">评分器</option>
			<option value="10">公式</option>
			<option value="11">文件</option>
		</select>
	</td>
	<td><input name="size_1" value="255" style="width:40px"/></td>
	<td><input name="default_1" value="张三"/></td>
	<td><input name="sample_1" value="张三"/></td>
	<td><input name="restrain_1" value="[^\\s]"/></td>
	<td><input name="remark_1" value="姓名不能为空"/></td>
	<td><input name="hidden_1" type="checkbox"></input></td>
</tr>
<tr>
	<td><input name="order_2" value="2" style="width:40px"/></td>
	<td><input name="name_2" value="年龄"/></td>
	<td><input name="code_2" value="AGE" style="width:40px"/></td>
	<td>
		<select name="type_2" >
			<option value="1">字符串</option>
			<option value="2" selected="selected">整数</option>
			<option value="3">小数</option>
			<option value="4">日期</option>
			<option value="5">时间</option>
			<option value="6">日期时间</option>
			<option value="7">单选</option>
			<option value="8">多选</option>
			<option value="9">评分器</option>
			<option value="10">公式</option>
			<option value="11">文件</option>
		</select>
	</td>
	<td><input name="size_2" value="" style="width:40px"/></td>
	<td><input name="default_2" value="20"/></td>
	<td><input name="sample_2" value=""/></td>
	<td><input name="restrain_2" value="[^\\s]"/></td>
	<td><input name="remark_2" value="年龄不能为空"/></td>
	<td><input name="hidden_2" type="checkbox"></input></td>
</tr>
<tr>
	<td colspan="5"><input type="checkbox" name="recordUser" id="recordUser"/><label for="recordUser">是否记录填报者用户名？</label></td>
	<td></td>
	<td></td>
	<td></td>
	<td></td>
	<td></td>
</tr>
<tr>
	<td colspan="5"><input type="checkbox" name="recordIp" id="recordIp"/><label for="recordIp">是否记录填报者IP？</label></td>
	<td></td>
	<td></td>
	<td></td>
	<td></td>
	<td></td>
</tr>
<tr>
	<td colspan="5"><input type="checkbox" name="recordTime" id="recordTime"/><label for="recordTime">是否记录填报时间？</label></td>
	<td></td>
	<td></td>
	<td></td>
	<td></td>
	<td></td>
</tr>
<tr>
	<td></td>
	<td></td>
	<td></td>
	<td></td>
	<td></td>
	<td></td>
	<td></td>
	<td></td>
	<td>
		<button type="submit">Submit</button>
	</td>
	<td></td>
</tr>

</table>

</form>
</div>

	</body>
	<script type="text/javascript">
	function restrain(reg,str){
		return(new RegExp(reg).test(str));
	}
	</script>
</html>

